package com.gregbugaj.nscaffold.type;

/**
 * 
 * Types based of the hibernate types
 * https://www.hibernate.org/hib_docs/v3/api/org/hibernate/type/package-summary.html
 * @author greg
 * 
 */
public enum PType {
	StringType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	TimestampType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	TimeType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	BooleanType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	TextType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	IntegerType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	DoubleType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	CollectionType("./models/components/jsf/Collection.ftl", "./models/components/jsf/OneToManyEdit.ftl"),

	ManyToOneType("./models/components/jsf/String.ftl", "./models/components/jsf/StringEdit.ftl"),
	OneToManyType("./models/components/jsf/OneToMany.ftl", "./models/components/jsf/OneToManyEdit.ftl"),
	OneToOneType("./models/components/jsf/OneToOne.ftl", "./models/components/jsf/OneToOneEdit.ftl");

	private String viewModel;
	private String editModel;
	private PType(String viewModel, String editModel){
		this.viewModel=viewModel;
		this.editModel=editModel;
	}
	
	public String getViewModel() {
		return viewModel;
	}
	public String getEditModel() {
		return editModel;
	}
}
